#include<iostream>
#include<string>
using namespace std;

int main()
{
  FILE* f = fopen("bite.txt", "w");
  if (f == nullptr)
  {
    perror("File open error");
    return -1;
  }

  string s("linux so easy!");
  fwrite(s.c_str(), 1, s.size(), f);
  fclose(f);
  f = nullptr;

  f = fopen("bite.txt", "r");
  if (f == nullptr)
  {
    perror("File open error");
    return -1;
  }
  char* s1[15];
  fread(s1, 1, 14,f);
  s1[14] = '\0';

  printf("%s\n",s1);

  fseek(f, 4, SEEK_SET);

  fclose(f);
  return 0;
}
